package z.t.b.db.data;

/**
 * 键值对
 */
public interface KeyValue {

    /**
     *
     * @param key
     * @param def
     * @return
     */
    Object getValue(String key, Object def);

    /**
     *
     * @param key
     * @param val
     */
    void setValue(String key, Object val);

    Number getNumber(String key, Number def);

    void putNumber(String key, Number val);

    String getString(String key, String def);

    void putString(String key, String val);

    void putObject(String key, Object val);

    int getInt(String key, int def);
}
